﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using MandalaySoft.Common;

namespace SIMS.BL
{
    public class UserDetail
    {
        public int UserDetailID { get; set; }
        public int UserID { get; set; }
        public string Title { get; set; }
        public string FirstName { get; set; }
        public string LastName { get; set; }
        public string MiddleName { get; set; }
        public string Suffix { get; set; }
        public string Gender { get; set; }
        public DateTime BirthDate { get; set; }
        public string Email { get; set; }
        public string PhoneNo { get; set; }
        public bool IsActive { get; set; }

        public int CreatedBy { get; set; }
        public string CreatedByName { get; set; }
        public DateTime CreatedDate { get; set; }

        public int ModifiedBy { get; set; }
        public string ModifiedByName { get; set; }
        public DateTime ModifiedDate { get; set; }

        public MyError Error { get; set; }

        public UserDetail()
        {
            ClearFields();
        }

        private void ClearFields()
        {
            UserDetailID = -1;
			UserID = -1;
			FirstName = string.Empty;
			LastName= string.Empty;
			MiddleName = string.Empty;
			Suffix = string.Empty;
			Gender = string.Empty;
            BirthDate = new DateTime(1900, 1, 1);
            Email = string.Empty;
            PhoneNo = string.Empty;
            IsActive = false;
            CreatedBy = -1;
            CreatedByName = string.Empty;
            CreatedDate = new DateTime(1900, 1, 1);
            ModifiedBy = -1;
            ModifiedByName = string.Empty;
            ModifiedDate = new DateTime(1900, 1, 1);
            Error = new MyError();
        }
    }
}
